//
//  ViewController.m
//  ZNChatDemo
//
//  Created by zhengn on 16/3/18.
//  Copyright © 2016年 Sniper_Personal. All rights reserved.
//

#import "ViewController.h"
#import "ZNChatController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    UIButton *btn = [UIButton buttonWithType:UIButtonTypeCustom];
    btn.frame = CGRectMake(100, 100, 100, 100);
    [self.view addSubview:btn];
    btn.backgroundColor = [UIColor cyanColor];
    [btn addTarget:self action:@selector(chat:) forControlEvents:UIControlEventTouchUpInside];
}

- (void)chat:(UIButton *)btn {
    ZNChatController *chatController = [[ZNChatController alloc] init];
    [self presentViewController:chatController animated:YES completion:nil];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
